package com.newblog2_0.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.newblog2_0.mapper.ArticleMapper;
import com.newblog2_0.model.ArticleInfo;
import com.newblog2_0.model.vo.ArticleInfoVo;
import com.newblog2_0.service.ArticleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created with Intellij IDEA.
 * Description;
 * User:TQ02
 * Data:2023-12-16
 * Time:15:12
 * Text：
 */
@Service
public class ArticleServiceImpl extends ServiceImpl<ArticleMapper, ArticleInfo> implements ArticleService {
        @Autowired
        private ArticleMapper articleMapper;

    @Override
    public List<ArticleInfoVo> getListByPage(Integer pasize, Integer offest) {
        return articleMapper.getListByPage(pasize,offest);
    }

    @Override
    public int getCount() {
        return articleMapper.getCount();
    }

    @Override
    public ArticleInfo getId(int aId) {
        return articleMapper.getId(aId);
    }

    @Override
    public int getinsert(int aId) {
        return articleMapper.getinsert(aId);
    }

    @Override
    public int getArtCount(int uId) {
        return articleMapper.getArtCount(uId);
    }
}
